#!/bin/bash
set -e;
if [ -n "$1" ];then

    whoname="$1"
else
    whoname=`whoami`

fi;
add2docker=${whoname};

sudo usermod -a -G docker ${add2docker};

sudo systemctl restart docker;
sudo chmod a+rw /var/run/docker.sock;